import request from '@/utils/request'

/***************************************************** activity ****************************************************/

/**
 * 获取活动列表
 * @returns 
 */
export const getAdminActivityListApi: IGetAdminActivityListApi = function(data) {
    return request.get(`htscrm/admin/activity/list`, data) as ReturnType<IGetAdminActivityListApi>
}
/**
 * 获取活动列表
 * @returns 
 */
export const getAdminActivityInfoApi: IGetAdminActivityInfoApi = function(id) {
    return request.get(`htscrm/admin/activity_info/${id}`) as ReturnType<IGetAdminActivityInfoApi>
}
/**
 * 获取分类列表
 * @returns 
 */
export const getAdminCateListApi: IGetAdminCateListApi = function() {
    return request.get(`htscrm/admin/category`) as ReturnType<IGetAdminCateListApi>
}
/**
 * 获取活动分享链接
 * @returns 
 */
export const getAdminActivityShareApi: IGetAdminActivityShareApi = function(id) {
    return request.get(`htscrm/admin/activity_share/${id}`) as ReturnType<IGetAdminActivityShareApi>
}
/**
 * 获取活动分享链接
 * @returns 
 */
export const getAdminAnswerListApi: IGetAdminAnswerListApi = function(data) {
    return request.get(`htscrm/admin/dati/${data.id}`) as ReturnType<IGetAdminAnswerListApi>
}
/**
 * 获取答题明细
 * @returns 
 */
export const getAdminAnswerRecordApi: IGetAdminAnswerRecordApi = function(data) {
    return request.get(`htscrm/admin/user_list/${data.id}`, data) as ReturnType<IGetAdminAnswerRecordApi>
}
/**
 * 设置红包
 * @returns 
 */
export const setRedPackApi: ISetRedPackApi = function(data) {
    return request.post(`htscrm/admin/set_red_pack/${data.id}`, data) as ReturnType<ISetRedPackApi>
}